<template>
  <div class="dashboard-container">
    <el-row :gutter="20">

      <el-col :span="14">
        <div class="grid-content bg-purple">
          <h4>机构概述</h4>
          <div class="ji">
            <div class="jizuo">
              <div> 西三旗分拣中心 </div>
              <div class="di">地址：北京顺义区天澜综合保税区123号 </div>
              <div class="fu">负责人：赵五金 16712345678 </div>
              <el-button class="an" type="warning" plain>查看营业部分布</el-button>
            </div>
            <div class="jiyou">
              <ul class="con">
                <li>
                  分拣中心(个)
                  <div class="qq">1</div>
                </li>
                <li>营业部(个)
                  <div class="ww">4</div>
                </li>
                <li>司机人数(个)
                  <div class="ee">48</div>
                </li>
                <li>快递员个数(个)
                  <div class="rr">64</div>
                </li>
              </ul>
            </div>
          </div>

        </div>
      </el-col>

      <el-col :span="10">
        <div class="grid-content bg-purple">
          <div class="jin">
            <h4>今日数据</h4>
            <div>2023-05-20 21:09</div>
          </div>

          <div class="container">
            <div class="item">
              <div class="ding">订单金额(元)</div>
              <div class="er">2,284</div>
              <div class="jiao">较昨日 +342</div>
            </div>
            <div class="item"><div class="ding">订单数量(笔)</div>
              <div class="er">193</div>
              <div class="jiao">较昨日 +27</div></div>
            <div class="item"><div class="ding">运输任务(次)</div>
              <div class="er">38</div>
              <div class="jiao">较昨日 +26</div></div>
          </div>
        </div>
      </el-col>
    </el-row>

    <el-row :gutter="20">

      <el-col :span="14">
        <div class="grid-content bg-purple">
          <div class="jin">
            <h4>待办任务</h4>
            <div> 2023-05-20 21:08 - 2023-05-22 23:59</div>
          </div>

          <div ref="chartBox" class="chart-box" style="height: 180px" />

        </div>
      </el-col>

      <el-col :span="10">
        <div class="grid-content bg-purple">
          <div class="jin">
            <h4>执行中任务</h4>
            <div> 2023-05-20 21:08</div>
          </div>

        </div>
      </el-col>
    </el-row>
  </div>
</template>
<script src='echarts.js'></script>
<script src='echarts-liquidfill.js'></script>
<script>

import { mapGetters } from 'vuex'

 const myChart = echarts.init(this.$refs.chartBox)
export default {
  name: 'Dashboard',
  computed: {
    ...mapGetters([
      'name'
    ])
  },

}

</script>

<style lang="scss" scoped>
.dashboard {
  &-container {
    margin: 30px;
  }
  &-text {
    font-size: 30px;
    line-height: 46px;

  }
}
.el-row {
    margin-bottom: 20px;

    &:last-child {
      margin-bottom: 0;

    }
  }
  .el-col {
    border-radius: 4px;

  }
  .bg-purple-dark {
    background:#99a9bf;
  }
  .bg-purple {
    background:white;
  }
  .bg-purple-light {
    background: #e5e9f2;
  }
  .grid-content {
    border-radius: 4px;
    min-height: 235px;
  }
  .row-bg {
    padding: 10px 0;
    background-color: #f9fafc;
  }
.ji{
  width: 100%;
display: flex;
justify-content: space-between;
}
.jizuo{
margin-left: 10px;
width: 350px;
height: 154px;

}

.jiyou{
  width: 350px;
height: 154px;

}

.di{
  margin-top: 10px;
  padding-bottom: 10px;
  padding-top: 5px;
  font-size: 14px;
    color: #818693;
}
.fu{
font-size: 14px;
    color: #818693;
}
.an{
margin-top: 20px;
margin-left: 10px;
}

.con{
  display: flex;
  margin: 0;
  padding: 10px;
  width: 100%;
  height: 100%;
  flex-wrap: wrap;
  justify-content: space-between;
  align-content: space-between;
}
  .con li{
width: 49.5%;
height: 49%;
list-style: none;

}
.qq,.ww,.ee,.rr{
font-size: 32px;
    font-weight: 700;
    color: #e15536;
    cursor: pointer;
    padding-top: 5px;
}

  .container {
      display: flex;
      text-align: center;
      height: 154px;

    }

    .item {
      flex-basis: 33.33%;
      background-color: #ccc; /* 可选，用于区分每个子项 */
      height: 154px;
    /* 可选，用于设置子项高度 */
    }
    .ding{
      margin-top: 20px;
    }
    .er{
       margin-top: 20px;
       font-size: 36px;
    color: #20232a;
    font-weight: 700;
    }
     .jiao{
       margin-top: 20px;
       color: #81869a;
    }

.jin{
display: flex;
justify-content: space-between;
}
.jin div{
margin-top: 20px;
 color: #81869a;
 font-size: 14px;
}
</style>
